[RF][RS] Store fit results in the AsymptoticCalculator - #23107
Open
guitargeek wants to merge 1 commit into
Open
Conversation
The AsymptoticCalculator performed all its fits in a local helper that saved a RooFitResult only to read off the minimum NLL value and then discarded it. Users therefore had no way to check programmatically whether the underlying fits actually converged, even though the calculator happily reports a significance also when they did not. Keep the RooFitResult objects of the four fits (unconditional and conditional, on observed and Asimov data) as members of the calculator and expose them with the new getters GetFitResultUncondObs(), GetFitResultCondObs(), GetFitResultUncondAsimov() and GetFitResultCondAsimov(). The results are now saved also when the minimization failed, so that the minimizer status and EDM of a non-converged fit can be inspected. The stored unconditional results are updated when GetHypoTest() finds a better minimum in its refit fallback. Also document in the class description that the fits can already be steered via the ROOT::Math::MinimizerOptions defaults for strategy and tolerance, which was the second request in the ticket. Closes JIRA [ROOT-10066](https://its.cern.ch/jira/browse/ROOT-10066). 🤖 Done with the help of AI
guitargeek
force-pushed
the
roostats-asymptotic-fit-results
branch
from
August 19, 2026 12:05
89be29b to
66a3875
Compare
Test Results 23 files 23 suites 3d 19h 8m 5s ⏱️ For more details on these failures, see this check. Results for commit 66a3875. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The AsymptoticCalculator performed all its fits in a local helper that saved a RooFitResult only to read off the minimum NLL value and then discarded it. Users therefore had no way to check programmatically whether the underlying fits actually converged, even though the calculator happily reports a significance also when they did not.
Keep the RooFitResult objects of the four fits (unconditional and conditional, on observed and Asimov data) as members of the calculator and expose them with the new getters GetFitResultUncondObs(), GetFitResultCondObs(), GetFitResultUncondAsimov() and GetFitResultCondAsimov(). The results are now saved also when the minimization failed, so that the minimizer status and EDM of a non-converged fit can be inspected. The stored unconditional results are updated when GetHypoTest() finds a better minimum in its refit fallback.
Also document in the class description that the fits can already be steered via the ROOT::Math::MinimizerOptions defaults for strategy and tolerance, which was the second request in the ticket.
Closes JIRA ROOT-10066.
🤖 Done with the help of AI